<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>二维码</title>
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1, user-scalable=no">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="stylesheet" href="../../plugins/mui/mui.min.css">
    <script src="../../js/statistics.js"></script>
    <style type="text/css">
        body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, form,  input, p, table, th, td ,select,option{
            padding: 0;
            margin: 0;
            list-style: none;
        }
        /*title的样式覆盖*/
        .header{
		    background: #2a2c33;
		    box-shadow: inherit;
		}
		.header a{
			color: #fff;
		}
		.mui-title{
			color: #fff;
			font-size: 18px;
		}
		.content-vh{
			min-height: 100vh;
			display: flex;
			flex-direction: column;
			justify-content: space-between;
			color: #333;
			position: relative;
		}
		.mui-ios .content-vh{
			min-height: calc(100vh - 20px);
		}
        .erweima{
            display: inline-block;
            padding:0;
            margin-bottom: 10px;
            width:50vw;
            height:50vw;
            background-size:100%;
            background-repeat: no-repeat;
        }
        .erweima.android{
        	background-image: url('../../images/my/index/barcode-android.png');
        }
        .erweima.ios{
        	background-image: url('../../images/my/index/barcode-ios.png');
        }
        .my-content{
            text-align: center;
            background-color: #fff;
        }
        .my-code{
            background: #E96D61;
            width:100%;
            margin-top:-5vw;
            padding: 5vw 0 0;
            border-top-left-radius: 53px;
            border-top-right-radius: 53px;
            text-align: center;  
        }
        .my-code-box{
        	display: -webkit-flex;
            display: flex;
            flex-direction: column;
           	align-items: center;
           	margin-bottom: 20px;
        }
        .my-code-box:last-child{
        	margin-bottom: 0;
        }
        .my-code-tit{
        	display: inline-block;
        	line-height: 1.4;
        	color: #fff;
        	margin: 5px 0;
        }
        .top-img{
            background: url("../../images/my/index/recommend_img1.png") no-repeat center center;
            background-size: contain;
            width:90vw;
            /*1.18855*/
            height:37vw;
            margin:0 auto;
        }
        .my-code-box a{
            display: block;
            margin:0 auto;
            text-align: center;
            width:80vw;
            height:38px;

            background: #ffffff;
            font-size: 15px;
            border-radius: 48px;
            line-height: 38px;
            color:#E96D61;
        }
        .my-code-box a:active{
            opacity: 0.8;
        }
    </style>
</head>
<body>

<header class="mui-bar mui-bar-nav header">
    <a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
    <h1 class="mui-title">二维码</h1>
</header>
<div class=" mui-content content-vh">
    <div class="top-img"></div>
    <div class="my-code">
    	<div class="my-code-box">
    		<div class="erweima ios"></div>
            <span class="my-code-tit">iOS版本下载</span>
    	</div>
        <div class="my-code-box">
        	<div class="erweima android"></div>
            <span class="my-code-tit">Android版本下载</span>
        </div> 
    </div>
</div>
<script type="text/javascript" src='../../plugins/jquery/jquery-3.1.0.min.js'></script>
<script src="../../plugins/mui/mui.min.js"></script>
<script type="text/javascript">
    mui.init({
// 				statusBarBackground: '#43ac45',//ios下设置顶部背景色
    });

    mui.plusReady(function(){
        //关闭等待框
        plus.nativeUI.closeWaiting();
        //显示当前页面
        mui.currentWebview.show('slide-in-right',200);
        mui(".my-code").on('tap','a',function(){
        	var _this = this,
        		id = _this.getAttribute('id'),
        		href;
        	if(id == 'one'){
        		href = "";
        	}else if (id == 'two'){
        		href = "";
        	}else{
        		return;
        	}
        	if(href){
        		if(plus.os.name == 'iOS'){
	        		var UIPasteboard  = plus.ios.importClass("UIPasteboard");
		            var generalPasteboard = UIPasteboard.generalPasteboard();
		            // 设置/获取文本内容:
		            generalPasteboard.setValueforPasteboardType(href, "public.utf8-plain-text");
	        	}else{
	        		var Context = plus.android.importClass("android.content.Context");
					var main = plus.android.runtimeMainActivity();
					var clip = main.getSystemService(Context.CLIPBOARD_SERVICE);
					plus.android.invoke(clip,"setText",href);
	        	}
        	}
        })
    });

</script>
</body>
</html>
